package com.niiwoo.activity.stage.enums.cashactivity;

import lombok.Getter;

@Getter
public enum ActivityStatusEnum {
	
	over((byte)1,"已结束"),//结束
	
	started((byte)2,"活动中"),//活动中
	
	not_started((byte)3,"未开始");//活动未开始
	
	private Byte code;
	
	private String text;
	
	ActivityStatusEnum(Byte code,String text){
		this.code=code;
		this.text=text;
	}
   
	public static ActivityStatusEnum getByCode(Byte code){
		for(ActivityStatusEnum s:ActivityStatusEnum.values()){
			if(code.equals(s.getCode())){
				return s;
			}
		}
		return null;
	}
}
